package com.neusoft.mapper;

import com.github.pagehelper.Page;
import com.neusoft.bean.RegisterBean;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDate;
import java.util.List;
import java.util.Map;

@Mapper
public interface RegisterMapper {
    String selectMaxCaseNumber();

    Integer selectCountByEmployeeId(Integer doctorId);

    Integer insertRegister(Map<String, Object> register);

    Integer selectCountByEmployeeIdAndVS(Integer employeeId);

    Integer selectWaitCountByEmployeeIdAndVS(Integer employeeId);

    Page<Map<String, Object>> selectWaitPatientByPage(@Param("employeeId") Integer employeeId,
                                                      @Param("caseNumber") String caseNumber,
                                                      @Param("realName") String realName);
    RegisterBean selectWaitCheckPatient(@Param("registerId")Integer registerId, @Param("caseNumber")String caseNumber, @Param("realName")String realName);
    Page<Map<String,Object>> selectPatientPage(@Param("caseNumber")String caseNumber,
                                               @Param("realName")String realName);


    Page<Map<String, Object>> selectAllPatientByPage(String caseNumber, String realName);


    void changeVisitState(@Param("caseNumber") Integer caseNumber);
    List<Map<String, Object>> selectPatient(@Param("caseNumber")String caseNumber,
                                            @Param("realName")String realName);
    RegisterBean selectWaitInspectionPatient(@Param("registerId")Integer registerId, @Param("caseNumber")String caseNumber, @Param("realName")String realName);

    RegisterBean selectWaitDisposalPatient(@Param("registerId")Integer registerId, @Param("caseNumber")String caseNumber, @Param("realName")String realName);

    Page<Map<String, Object>> selectDisposalPatientByPage(@Param("caseNumber") String caseNumber,
                                                          @Param("realName") String realName);

    Page<Map<String, Object>> selectPatientByPage(String caseNumber, String realName);

    Page<Map<String, Object>> selectPatientByPages(String caseNumber, String realName);

    Page<Map<String, Object>> selectSearchPatientByPage(@Param("caseNumber") String caseNumber,
                                                        @Param("realName") String realName);


    //y
    List<Map<String, Object>> selectCheckById(@Param("realName") String realName,
                                          @Param("caseNumber") String caseNumber);
}
